import constants from '@/commons/constants';
const moduleCode = constants.MODULE_MALL_CODE;

export default [
    {
        path: '/finance',
        redirect: '/finance/income'
    },
    {
        path: '/finance/income',
        name: 'financeIncome',
        component: () => import('@/views/mall/finance/income/index.vue'),
        meta: {
            title: '订单收入',
            code: 'order_income:view',
            moduleCode
        }
    },
    {
        path: '/finance/baohutong',
        name: 'financeBaohutong',
        component: () => import('@/views/mall/finance/baohutong/index.vue'),
        meta: {
            title: '宝户通账户',
            keepAlive: true,
            code: 'baohu_account',
            moduleCode
        }
    },
    {
        path: '/finance/baohutong/detail',
        component: () => import('@/views/mall/finance/baohutong/detail/index.vue'),
        meta: {
            title: '详情',
            permAuth: false, // todo菜单权限
            moduleCode
        }
    },
    {
        path: '/finance/baohutong/person',
        component: () => import('@/views/sys/pay/person/open.vue'),
        meta: {
            title: '开通账户',
            permAuth: false, // todo菜单权限
            moduleCode
        }
    },
    {
        // 小程序-财务管理-个体账户开户
        path: '/finance/baohutong/individual',
        component: () => import('@/views/mall/finance/baohutong/individual/perAccount.vue'),
        meta: {
            title: '开通账户',
            keepAlive: true,
            permAuth: false, // todo菜单权限
            moduleCode
        }
    },
    {
        // 开通企业账户-财务管理/宝户通账户管理/开通账户
        path: '/finance/baohutong/enterprise',
        component: () => import('@/views/sys/pay/enterprise/index.vue'),
        meta: {
            title: '开通账户',
            permAuth: false,
            moduleCode
        }
    }
];
